#include"OpencvAPI.h"

int main()
{
	Mat srcImg;
	ReadImage(srcImg);	
	cvtColor(srcImg, srcImg, COLOR_BGR2GRAY);

	Mat srcImg_1 = srcImg.clone();
	threshold(srcImg, srcImg,50, 255, THRESH_BINARY);
	Mat outPutImg;
	Connection(srcImg, outPutImg);
	Mat outPutImg_2;
	SelectShape(srcImg, outPutImg_2, "area", 20, 6200);

	Mat outPutImg_3;
	ReduceDomain(srcImg_1, outPutImg_2, outPutImg_3);
	imshow("paramOutRegion", outPutImg_3);
	waitKey(0);
	system("pause");
	return 0;
}